Adaptive buffering of data received from a sensor

ABSTRACT

In a method of adaptive buffering in a mobile device having a host processor and a sensor processor coupled with the host processor, the sensor processor is used to buffer data received from a sensor that is operated by the sensor processor, wherein the data is buffered by the sensor processor into a circular data buffer. In response to the sensor processor detecting triggering data within the received data: the sensor processor sets a start-end marker in the circular data buffer; and a command is sent from the sensor processor to a second processor.

BACKGROUND

Advances in technology have enabled the introduction of electronic devices that feature an ever increasing set of capabilities. Smartphones, for example, now offer sophisticated computing and sensing resources together with expanded communication capability, digital imaging capability, and user experience capability. Likewise, tablets, wearables, media players, Internet connected devices (which may or may not be mobile), and other similar electronic devices have shared in this progress and often offer some or all of these capabilities. Many of the capabilities of electronic devices, and in particular mobile electronic devices, are enabled by sensors (e.g., accelerometers, gyroscopes, pressure sensors, thermometers, acoustic sensors, etc.) that are included in the electronic device. That is, one or more aspects of the capabilities offered by electronic devices will rely upon information provided by one or more of the sensors of the electronic device in order to provide or enhance the capability. In general, sensors detect or measure physical or environmental properties of the device or its surroundings, such as one or more of the orientation, velocity, and acceleration of the device, and/or one or more of the temperature, acoustic environment, atmospheric pressure, etc. of the device and/or its surroundings, among other

BRIEF DESCRIPTION OF DRAWINGS

The accompanying drawings, which are incorporated in and form a part of the Description of Embodiments, illustrate various embodiments of the subject matter and, together with the Description of Embodiments, serve to explain principles of the subject matter discussed below. Unless specifically noted, the drawings referred to in this Brief Description of Drawings should be understood as not being drawn to scale. Herein, like items are labeled with like item numbers.

FIG. 1 is a block diagram of a mobile electronic device which includes a sensor processing unit, in accordance with various embodiments.

FIG. 2 is a block diagram illustrating a communicative coupling between the mobile electronic device of FIG. 1 and an external processor that is external to the mobile electronic device, in accordance with various embodiments.

FIG. 3A illustrates a block diagram of a circular data buffer of a sensor processing unit, according to various embodiments.

FIG. 3B illustrates example data buffering operations with the circular data buffer of FIG. 3A which take place in response to the sensor processor detecting triggering data, according to various embodiments.

FIG. 3C illustrates example data buffering operations with the circular data buffer of FIG. 3A which take place in response to the sensor processor detecting triggering data, according to various embodiments.

FIG. 3D illustrates example data buffering operations with the circular data buffer of FIG. 3A which take place in response to the sensor processor detecting triggering data, according to various embodiments.

FIG. 3E illustrates example data buffering operations with the circular data buffer of FIG. 3A which take place in response to the sensor processor detecting triggering data, according to various embodiments.

FIG. 3F illustrates example data buffering operations with the circular data buffer of FIG. 3A which take place in response to the sensor processor detecting triggering data, according to various embodiments.

FIG. 3G illustrates example data buffering operations with the circular data buffer of FIG. 3A which take place in response to the sensor processor detecting triggering data, according to various embodiments.

FIGS. 4A-4G illustrate a flow diagram of an example method of adaptive buffering in a mobile device having a host processor and a sensor processor coupled with the host processor, according to various embodiments.

DESCRIPTION OF EMBODIMENTS

Reference will now be made in detail to various embodiments of the subject matter, examples of which are illustrated in the accompanying drawings. While various embodiments are discussed herein, it will be understood that they are not intended to limit to these embodiments. On the contrary, the presented embodiments are intended to cover alternatives, modifications and equivalents, which may be included within the spirit and scope the various embodiments as defined by the appended claims. Furthermore, in this Description of Embodiments, numerous specific details are set forth in order to provide a thorough understanding of embodiments of the present subject matter. However, embodiments may be practiced without these specific details. In other instances, well known methods, procedures, components, and circuits have not been described in detail as not to unnecessarily obscure aspects of the described embodiments.

Notation and Nomenclature

Some portions of the detailed descriptions which follow are presented in terms of procedures, logic blocks, processing and other symbolic representations of operations on data bits within a computer memory. These descriptions and representations are the means used by those skilled in the data processing arts to most effectively convey the substance of their work to others skilled in the art. In the present application, a procedure, logic block, process, or the like, is conceived to be one or more self-consistent procedures or instructions leading to a desired result. The procedures are those requiring physical manipulations of physical quantities. Usually, although not necessarily, these quantities take the form of electrical or magnetic signals capable of being stored, transferred, combined, compared, and otherwise manipulated in an electronic device.

It should be borne in mind, however, that all of these and similar terms are to be associated with the appropriate physical quantities and are merely convenient labels applied to these quantities. Unless specifically stated otherwise as apparent from the following discussions, it is appreciated that throughout the description of embodiments, discussions utilizing terms such as “using,” “detecting,” “sending,” “buffering,” “increasing,” “replacing,” “passing,” “validating,” “setting,” and “decreasing,” or the like, refer to the actions and processes of an electronic device such as: a sensor processing unit, a sensor processor, a host processor, a processor, a sensor, a memory, a mobile electronic device, or the like, or a combination thereof. The electronic device manipulates and transforms data represented as physical (electronic and/or magnetic) quantities within the electronic device's registers and memories into other data similarly represented as physical quantities within the electronic device's memories or registers or other such information storage, transmission, processing, or display components.

Embodiments described herein may be discussed in the general context of processor-executable instructions residing on some form of non-transitory processor-readable medium, such as program modules, executed by one or more computers or other devices. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform particular tasks or implement particular abstract data types. The functionality of the program modules may be combined or distributed as desired in various embodiments.

In the figures, a single block may be described as performing a function or functions; however, in actual practice, the function or functions performed by that block may be performed in a single component or across multiple components, and/or may be performed using hardware, using software, or using a combination of hardware and software. To clearly illustrate this interchangeability of hardware and software, various illustrative components, blocks, modules, circuits, and steps have been described generally in terms of their functionality. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the overall system. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present disclosure. Also, the example mobile electronic device(s) described herein may include components other than those shown, including well-known components.

The techniques described herein may be implemented in hardware, software, firmware, or any combination thereof, unless specifically described as being implemented in a specific manner. Any features described as modules or components may also be implemented together in an integrated logic device or separately as discrete but interoperable logic devices. If implemented in software, the techniques may be realized at least in part by a non-transitory processor-readable storage medium comprising instructions that, when executed, perform one or more of the methods described herein. The non-transitory processor-readable data storage medium may form part of a computer program product, which may include packaging materials.

The non-transitory processor-readable storage medium may comprise random access memory (RAM) such as synchronous dynamic random access memory (SDRAM), read only memory (ROM), non-volatile random access memory (NVRAM), electrically erasable programmable read-only memory (EEPROM), FLASH memory, other known storage media, and the like. The techniques additionally, or alternatively, may be realized at least in part by a processor-readable communication medium that carries or communicates code in the form of instructions or data structures and that can be accessed, read, and/or executed by a computer or other processor.

The various illustrative logical blocks, modules, circuits and instructions described in connection with the embodiments disclosed herein may be executed by one or more processors, such as one or more motion processing units (MPUs), sensor processing units (SPUs), audio processing units (APUs), host processor(s) or core(s) thereof, digital signal processors (DSPs), general purpose microprocessors, application specific integrated circuits (ASICs), application specific instruction set processors (ASIPs), field programmable gate arrays (FPGAs), or other equivalent integrated or discrete logic circuitry. The term “processor,” as used herein may refer to any of the foregoing structures or any other structure suitable for implementation of the techniques described herein. In addition, in some aspects, the functionality described herein may be provided within dedicated software modules or hardware modules configured as described herein. Also, the techniques could be fully implemented in one or more circuits or logic elements. A general purpose processor may be a microprocessor, but in the alternative, the processor may be any conventional processor, controller, microcontroller, or state machine. A processor may also be implemented as a combination of computing devices, e.g., a combination of an SPU/MPU and a microprocessor, a plurality of microprocessors, one or more microprocessors in conjunction with an SPU core, MPU core, or any other such configuration.

Overview of Discussion

Example embodiments described herein, improve the usability of electronic devices. One or more sensors and sensor processing unit(s) which operate it/them may operate to detect or measure physical or environmental properties of an electronic device (e.g., a mobile electronic device or an internet of things (IOT) device) or its surroundings while a host processor portion of the electronic device in which the sensor is disposed is in a low-power mode (e.g., a sleep mode) and/or while the host processor has off-loaded tasks to a dedicated processor. A low-power mode operates a host processor at less than its full-power mode/full-capability mode in order to conserve power use of the electronic device. One or more tasks may be off-loaded from a host processor to a dedicated processor to free up processing cycles on the host processor and/or because the dedicated processor is more efficient in energy or calculation on the off-loaded task(s). Mobile electronic devices include, but are not limited to, electronic devices such as: a cellular telephone, a media player, a tablet computer, a notebook computer, digital camera, and a wearable (e.g., a wrist wearable device like a watch, a pendant, a fitness tracker, or the like).

Any always-on feature in a mobile electronic device or an IOT electronic device has to deal with strict low-power constraints either to conserve battery power or to be energy efficient. This implies that the electronic device and any algorithms running thereon should be frugal in terms of computational resources and that higher-level functions should be relegated to the post-wakeup phase on the host processor for local operations, or else to a cloud-based processor for remote operations. Often in a device with a host processor and a sensor processor, the sensor processor uses less power and is thus kept active when the host processor is powered down or placed in a low-power mode (e.g., a sleep mode) that uses less power than a full-power mode. Various sensor processing units and schemes described herein allow for a reduction in data memory size used in the low-power, always-on module, which is often a sensor processor unit. Reducing data memory size reduces manufacturing cost, chip size, and decreases power requirements that would be associated with operating a larger data memory. This is of interest especially for high-data rate audio applications like voice wake-up or environmental acoustic sensing. When voice-wakeup, environmental acoustic sensing, or other sensing remains active while a host processor of an electronic device is in a low-power mode, there is often a need for buffering of data received from one or more sensors.

The need for buffering of received data stems from at least two constraints. The first constraint is the time it takes to wake up the host processor after triggering data (e.g., a spoken keyword) has been detected. Between the time the wake-up decision is made and the time the host processor is ready to accept the received data, new data continues to arrive that needs to be buffered in order to not get lost. The second constraint is that the host processor or some other processor may be utilized to re-process the received data that was initially processed by a sensor processor. This allows, for example, a higher-level processing function to revisit a previous analysis performed by a lower-level processing function. For example, a keyword audio signal may be originally processed by a simple speech recognition algorithm operating on a sensor processor in an electronic device and then reprocessed, for validation, by a more powerful speech recognition algorithm running on a larger processor, such as the host processor, of the electronic device.

To satisfy these constraints, a low-power, always-on algorithm can buffer a certain amount of received data from one or more sensors. For example, a sensor processing unit which operates an always-on voice wake-up algorithm may buffer several seconds of audio data and possibly data from other sensors as well. As will be described herein, the size requirement of a buffer used for buffering this data can be reduced by using a circular data buffer and by adaptively applying data compression and/or other techniques to efficiently utilize the data buffer.

Discussion begins with a description of a mobile electronic device with a sensor processing unit that includes at least one sensor. This is followed by some examples of operational descriptions of the mobile electronic device, the sensor processing unit, and one or more sensor. An example circular data buffer of the sensor processing unit is described. Numerous examples data buffering operations with the circular data buffer are described. Finally, operation of the mobile electronic device, the sensor processing unit, and the circular data buffer, is then further described in conjunction with description of example method(s) of adaptive buffering in a mobile device having a host processor and a sensor processor coupled with the host processor.

Example Mobile Electronic Device

Turning now to the figures, FIG. 1 is a block diagram of an example mobile electronic device 100. As will be appreciated, mobile electronic device 100 may be implemented as a device or apparatus, such as a handheld mobile electronic device, that can be moved in space by a human user. That is, mobile electronic device 100 is small enough to be held in the hand of a human user, in various embodiments. For example, such a mobile electronic device may be, without limitation, a mobile telephone phone (e.g., smartphone, cellular phone, a cordless phone running on a local network, or any other cordless telephone handset), a wired telephone (e.g., a phone attached by a wire), a personal digital assistant (PDA), a video game player, video game controller, a navigation device, an activity or fitness tracker device (e.g., bracelet, clip, band, or pendant), a smart watch or other wearable device, a mobile internet device (MID), a personal navigation device (PND), a digital still camera, a digital video camera, a portable music player, a portable video player, a portable multi-media player, a remote control, a mobile IOT device, or a combination of one or more of these devices. The exact configuration of the device may depend on the type of device and its intended functions. Therefore, the block diagram of FIG. 1 is merely an example, and the different blocks may be otherwise distributed over host and sensor processing unit 170, for example all blocks may be integrated into a standalone sensor processing unit.

As depicted in FIG. 1, mobile electronic device 100 may include a host processor 110, a host bus 120, a host memory 130, and a sensor processing unit 170. Some embodiments of mobile electronic device 100 may further include one or more of a display 140, an interface 150, a transceiver 160 (all depicted in dashed lines), a sensor 178 (e.g., 178-1), and/or other components. In various embodiments, electrical power for mobile electronic device 100 is provided by a mobile power source such as a battery, when not being actively charged.

Host processor 110 can be one or more microprocessors, central processing units (CPUs), DSPs, general purpose microprocessors, ASICs, ASIPs, FPGAs or other processors which run software programs or applications, which may be stored in host memory 130, associated with the functions and capabilities of mobile electronic device 100.

Host bus 120 may be any suitable bus or interface to include, without limitation, a peripheral component interconnect express (PCIe) bus, a universal serial bus (USB), a universal asynchronous receiver/transmitter (UART) serial bus, a suitable advanced microcontroller bus architecture (AMBA) interface, an Inter-Integrated Circuit (I2C) bus, a serial digital input output (SDIO) bus, a serial peripheral interface (SPI) or other equivalent. In the embodiment shown, host processor 110, host memory 130, display 140, interface 150, transceiver 160, sensor processing unit 170, and other components of mobile electronic device 100 may be coupled communicatively through host bus 120 in order to exchange commands and data. Depending on the architecture, different bus configurations may be employed as desired. For example, additional buses may be used to couple the various components of mobile electronic device 100, such as by using a dedicated bus between host processor 110 and memory 130.

Host memory 130 can be any suitable type of memory, including but not limited to electronic memory (e.g., read only memory (ROM), random access memory, or other electronic memory), hard disk, optical disk, or some combination thereof. Multiple layers of software can be stored in host memory 130 for use with/operation upon host processor 110. For example, an operating system layer can be provided for mobile electronic device 100 to control and manage system resources in real time, enable functions of application software and other layers, and interface application programs with other software and functions of mobile electronic device 100. Similarly, a user experience system layer may operate upon or be facilitated by the operating system. The user experience system may comprise one or more software application programs such as menu navigation software, games, device function control, gesture recognition, image processing or adjusting, voice recognition, navigation software, communications software (such as telephony or wireless local area network (WLAN) software), and/or any of a wide variety of other software and functional interfaces for interaction with the user can be provided. In some embodiments, multiple different applications can be provided on a single mobile electronic device 100, and in some of those embodiments, multiple applications can run simultaneously as part of the user experience system. In some embodiments, the user experience system, operating system, and/or the host processor 110 may operate in a low-power mode (e.g., a sleep mode) where very few instructions are processed. Such a low-power mode may utilize only a small fraction of the processing power of a full-power mode (e.g., an awake mode) of the host processor 110.

Display 140, when included, may be a liquid crystal device, (organic) light emitting diode device, or other display device suitable for creating and visibly depicting graphic images and/or alphanumeric characters recognizable to a user. Display 140 may be configured to output images viewable by the user and may additionally or alternatively function as a viewfinder for camera.

Interface 150, when included, can be any of a variety of different devices providing input and/or output to a user, such as audio speakers, touch screen, real or virtual buttons, joystick, slider, knob, printer, scanner, computer network I/O device, other connected peripherals and the like.

Transceiver 160, when included, may be one or more of a wired or wireless transceiver which facilitates receipt of data at mobile electronic device 100 from an external transmission source and transmission of data from mobile electronic device 100 to an external recipient. By way of example, and not of limitation, in various embodiments, transceiver 160 comprises one or more of: a cellular transceiver, a wireless local area network transceiver (e.g., a transceiver compliant with one or more Institute of Electrical and Electronics Engineers (IEEE) 802.11 specifications for wireless local area network communication), a wireless personal area network transceiver (e.g., a transceiver compliant with one or more IEEE 802.15 specifications for wireless personal area network communication), and a wired a serial transceiver (e.g., a universal serial bus for wired communication).

Sensor 178-1, when included, may comprise, without limitation: a temperature sensor, an atmospheric pressure sensor, an infrared sensor, an ultrasonic sensor, a radio frequency sensor, a navigation satellite system sensor (such as a global positioning system receiver), an acoustic sensor (e.g., a microphone), an image sensor, an inertial or motion sensor (e.g., a gyroscope, accelerometer, or magnetometer) for measuring the orientation or motion of the sensor in space, or other type of sensor for measuring other physical or environmental quantities. Sensor 178-1 is coupled with host bus 120 for communication with host processor 110, host memory 110, and sensor processing unit 170. Although depicted as being included with/native to mobile electronic device 100, sensor 178-1 may be located external to mobile electronic device 100 and communicate with mobile electronic device 100 via a wired or wireless coupling.

Mobile electronic device 100 also includes a general purpose sensor assembly in the form of integrated sensor processing unit (SPU) 170 which includes sensor processor 172, memory 176, at least one sensor 178 (178-2, 178-3, . . . 178-n), a buffer 177, and a bus 174 for facilitating communication between these and other components of sensor processing unit 170. In some embodiments, some or all of the components illustrated in sensor processing unit 170 may be embodied on a single integrated circuit. It should be appreciated that sensor processing unit 170 may be manufactured as a stand-alone unit (e.g., an integrated circuit), that may exist separately from a larger electronic device. Although depicted as a portion of mobile electronic device 100, in some embodiments, sensor processing unit 170 may be incorporated in an electronic device that is not mobile; one non-limiting example uses sensor processing unit 170 in a voice recognition component of an Internet connected “smart” refrigerator.

Sensor processor 172 can be one or more microprocessors, CPUs, DSPs, general purpose microprocessors, ASICs, ASIPs, FPGAs or other processors which run software programs, which may be stored in memory 176, associated with the functions of sensor processing unit 170.

Bus 174 may be any suitable bus or interface to include, without limitation, a peripheral component interconnect express (PCIe) bus, a universal serial bus (USB), a universal asynchronous receiver/transmitter (UART) serial bus, a suitable advanced microcontroller bus architecture (AMBA) interface, an Inter-Integrated Circuit (I2C) bus, a serial digital input output (SDIO) bus, a serial peripheral interface (SPI) or other equivalent. Depending on the architecture, different bus configurations may be employed as desired. In the embodiment shown, sensor processor 172, memory 176, buffer 177, sensor 178, and other components of sensor processing unit 170 may be communicatively coupled through bus 174 in order to exchange data.

Memory 176 can be any suitable type of memory, including but not limited to electronic memory (e.g., read only memory (ROM), random access memory, or other electronic memory). Memory 176 may store algorithms or routines or other instructions for processing data received from one or more sensors 178, as well as the received data either in its raw form or after some processing. Such algorithms and routines may be implemented by sensor processor 172 and/or by logic or processing capabilities included in sensor 178.

Buffer 177 is a data buffer that temporarily stores data received from one or more sensors 178. Data buffer 177 may store the received data in its raw form, or in a processed form after the raw data has been processed in some fashion. In some embodiments, buffer 177 may be a circular buffer. Buffer 177 may be operated to buffer the received data when host processor 110 is in a low-power mode. Additionally, buffer 177 may be operated to store the received data when one or more of sensor processor and memory 176 are operated in a low-power mode. Although depicted as an independent entity, in some embodiments, buffer 177 may be a portion or subset of memory 176.

A sensor 178 may comprise, without limitation: a temperature sensor, an atmospheric pressure sensor, an infrared sensor, an ultrasonic sensor, a radio frequency sensor, a navigation satellite system sensor (such as a global positioning system receiver), an acoustic sensor (e.g., a microphone), an image sensor, an inertial or motion sensor (e.g., a gyroscope, accelerometer, or magnetometer) for measuring the orientation or motion of the sensor in space, or other type of sensor for measuring other physical or environmental quantities. In one example, sensor 178-2 may comprise an acoustic sensor, sensor 178-3 may comprise a second acoustic sensor, and sensor 178-n may comprise an internal motion sensor.

In some embodiments, the mobile electronic device 100 may contain more than one sensor processing unit 170. The different sensor processing units 170 may communicate which each other or with the host over host bus 120. The different sensor processing units 170 may contain different sensors, or may contain identical sensors.

In some embodiments, one or more sensors 178 may be implemented using a micro-electro-mechanical system (MEMS) that is integrated with sensor processor 172 and one or more other components of SPU 170 in a single chip or package.

Although depicted as being included within sensor processing unit 170, one, some, or all sensors 178 may be disposed externally to sensor processing unit 170 in various embodiments. The sensors may be referred to as external sensors and may be connected to host bus 120 to communicate with e.g., host processor 110 or sensor processing unit 170.

FIG. 2 is a block diagram illustrating a wireless communicative coupling 205 between the mobile electronic device 100 of FIG. 1 and an external processor 210 that is external to the mobile electronic device 100, in accordance with various embodiments. The communication over wireless communicative coupling 205 may be a request, command, or instruction, a transmission of data received from a sensor 178, some other communication, or some combination of these and/or other communications. In some embodiments, as will be further described, the communication may be sent from sensor processing unit 170, such as via transceiver 160. In some embodiments, when host processor 110 is in a low-power mode, such communication may not involve host processor 110.

Example Sensor Processing Unit Operation

FIGS. 3A-3G illustrate block diagrams of an example circular data buffer 177 and various aspects of adaptive buffering of data received from a sensor 178, according to one or more embodiments.

FIG. 3A illustrates block diagram of a circular data buffer 177 of a sensor processing unit 170, according to various embodiments. Circular data buffer is a data structure that uses a single, fixed-size memory 305 and collection of its ordered memory addresses 311 (311-1, 311-2, 311-3, 311-4, 311-5, 311-6, 311-7, 311-8, 311-9, 311-10, 311-12, 311-13, 311-14, 311-15, 311-16, 311-17 . . . 311-(n−1), and 311-n) as if the ordered memory addresses were connected end-to-end (e.g., 311-n connected back to 311-1 as shown by dashed line 306). In FIG. 3A, all of memory addresses 311 are blank and unwritten except for address 311-1. Write pointer 320 is shown pointing to address 311-1 and a first portion of data received from a sensor 178 (e.g., acoustic sensor 178-2) has been written as represented by the capital letter “A.” In this example, it should be appreciated that the data is a binary or other representation of acoustic data and is not actually the letter “A.” Likewise, in other examples illustrated and described herein, the capital letters depicted in memory addresses 311 are merely symbolic representations and are not intended to be visual depictions of the actual received data. The size of circular data buffer 177 may depend, for example, on the type of sensor, the type of sensor data, the application the sensor data is intended for, or the power mode of the sensor processing unit 170 or mobile electronic device 100. In one embodiment, circular data buffer 177 may be of sufficient size to buffer several seconds (e.g., 3-10 seconds of data received from a sensor 178), before beginning to overwrite itself with newly received data after circling back to the same memory addresses that were previously written with buffered data. In various embodiments, received data from a sensor 178 may be continuously written in a circular fashion into circular data buffer 177 in a raw or processed fashion as the data streams in from the sensor.

In some embodiments, as the streamed data is received from a sensor 178, sensor processor 172 continually detects for the appearance of triggering data within the stream. This detection may be done by comparing the data, or section of the data, in the buffer to the triggering data. When the streamed data is from an acoustic sensor the triggering data may be an acoustic pattern that matches a specific sound or a word or series of words spoken by a human. The word or series may comprise a command (e.g., a wake-up command) which may be followed by an instruction. Sensor processor 172 may operate a speech recognition algorithm that is tailored to recognize a single spoken word, a small set of spoken words, and/or one or more short spoken phrases. For example, and without limitation, sensor processor 172 may be configured to recognize the word “awaken,” or the phrase “hey siri,” or the phrase “wake up” or the phrase “OK google” as a keyword/phrase that is the triggering data within the received data from a sensor 178. Detection of this triggering data causes sensor processor 172 to send a command to a second processor. In some embodiments, the command is a wake-up command sent to host processor 110 commanding it to power-up to a higher operational mode from a low-power mode.

Start-end Marker Setting

In general a start-end marker may be set in circular data buffer 177 at a position relative to the trigger data, for example, in advance of triggering data, at the beginning point of triggering data, or at the end of triggering data. The location at which a start-end marker is set may be adapted, without limitation thereto, based on one or more of: the type of sensor data being recorded, the timeliness in which a host processor can be awaked so that buffered data can be forwarded out of circular data buffer 177 before being overwritten, the speed at which buffered data can be read out of circular data buffer 177, and the type (if any) of validation and/or processing that is to be accomplished by a second processor on the buffered data.

FIG. 3B illustrates example data buffering operations with the circular data buffer 177 of FIG. 3A which take place in response to the sensor processor (e.g., 172) detecting triggering data 310, according to various embodiments. In FIG. 3B, write pointer 320 is positioned at memory address 311-16, and memory addresses 311-1 to 311-16 have been sequentially written with received data. In an example where received data is being received from an acoustic sensor 178, sensor processor 172 has detected triggering data 310, such as via speech recognition, in memory addresses 311-9 to 311-15. In response to detecting of the triggering data 310 within the received data, sensor processor 172 has set a start-end marker 330. Setting start-end marker 330 marks the beginning of the buffer content that is retained and used for the next stage, such as being passed to a second processor. The ‘T’ in buffer address 311-9 represents the new beginning of circular data buffer 177. The ‘H’ in buffer address 311-8 represents the new end of circular data buffer 177 (before starting to overwrite). In various embodiments, the second processor may be a host processor 110 of mobile device 100, an external processor 210 in a datacenter (e.g., in the “cloud”), or an external processor 210 in an electronic device that is separate from mobile device 100). Start-end marker 330 also marks a circular end of circular data buffer 177, as an address that should not be overwritten until the received data buffered in it can be transmitted elsewhere and/or until it can be confirmed that an action has taken place such as waking up a host processor. As will be further discussed, various adaptive buffering techniques may be implemented to prevent unintentional overwriting of the starting memory address marked by the start-end marker 330.

As depicted in FIG. 3B, sensor processor 172 has placed start-end marker 330 at the beginning of the triggering data 310. Start-end marker 330 may be positioned in places other than at the beginning of triggering data 310, in other embodiments. FIG. 3C and FIG. 3D show some examples other positions that a start-end marker 330 may be placed by sensor processor 172.

In some embodiments, sensor processor 172 may additionally set one or more data markers 340 to mark or point to various portions of data of interest. In FIG. 3B, data marker 340 has been positioned at the end of triggering data 310. In this fashion, start-end marker 330 marks the beginning (memory address 311-9) and data marker 340 marks the end (memory address 311-15) of the range of received data that comprises the triggering data 310. In some embodiments, one or more data markers 340 may be used to identify or indicate specific section of a command that follows the triggering data 310. In some embodiments, triggering data 310 and/or a command, or sections of commands, are transmitted elsewhere to a second processor for reprocessing and/or validation and these markings denote which portion of the buffered received data should be sent. By setting start-end marker 330 at the beginning of the triggering data 310, buffering can be adapted to preserve the triggering data 310 and prevent it from being unintentionally overwritten.

FIG. 3C illustrates example data buffering operations with the circular data buffer 177 of FIG. 3A which take place in response to the sensor processor (e.g., 172) detecting triggering data 310, according to various embodiments. FIG. 3C is similar to FIG. 3B except that start-end marker 330 has been set at the end of the triggering data 310 and data-marker 340 has been set at the beginning of triggering data 310. In this fashion, data marker 340 marks the beginning (memory address 311-9) and start-end marker 330 marks the end (memory address 311-15) of the range of received data that comprises the triggering data 310. In some embodiments, triggering data 310 is transmitted elsewhere to a second processor for reprocessing and/or validation and these markings denote which portion of the buffered received data should be sent. By setting start-end marker 330 at the end of the triggering data 310, buffering can be adapted to preserve buffered received data just after the triggering data 310 and prevent it from being unintentionally overwritten. This is useful when the sensor processor issues a command based on the triggering data 310, but may not be configured to recognize a follow-on command, instruction, or request that may immediately follow the triggering data 310. Setting the start-end marker 330 at the end of triggering data 310 frees up more buffer space for buffering a command, instruction, or request following the keyword of represented in triggering data 310, but does not allow a validation of the triggering data 310 in a later stage if the triggering data 310 happens to be overwritten before it can be transmitted to another location for validation.

FIG. 3D illustrates example data buffering operations with the circular data buffer 177 of FIG. 3A which take place in response to the sensor processor (e.g., 172) detecting triggering data 310, according to various embodiments. FIG. 3D is similar to FIG. 3B except that start-end marker 330 has been set a predetermined distance (e.g., two memory addresses) in front of triggering data 310 at the beginning of buffer address 311-7. In this embodiment, two data-markers 340 have been set as well. Data marker 340-1 is set at the beginning of triggering data 310, and data marker 340-2 is set at the end of the triggering data 310. In this fashion, data markers 340-1 and 340-2 denote the range of buffered data that comprises the triggering data 310. In some embodiments, triggering data 310 is transmitted elsewhere to a second processor for reprocessing and/or validation and these markings denote which portion of the buffered received data should be sent. In some embodiments, some predetermined additional received data immediately prior to the triggering data may also be transmitted elsewhere to a second processor along with the triggering data 310. By setting start-end marker 330 a predetermined distance in front of the triggering data 310, buffering can be adapted to preserve this buffered received data just prior to the triggering data 310 and prevent it from being unintentionally overwritten.

Extending the buffer content to a time before the start of detection of triggering data 310 in the fashion illustrated in FIG. 3D enables validation (e.g., re-doing/double-checking) of the triggering data detection from a time period before the occurrence of the already “identified” triggering data 310. This allows for the context of the appearance of the triggering data 310 to also be evaluated as part of the validation. This validation is performed with a more sophisticated algorithm at a later stage (e.g., after being transmitted to a more sophisticated second processor than sensor processor 172). This validation can place mobile device 100 and its host processor 110 back in low-power mode without fully awakening or else shortly after awakening, in case of a false positive. In this example, a false positive means that the sensor processor recognized the triggering data, but that the second processor, using a more sophisticated algorithm, did not confirm that the data was indeed equal to the triggering data. This conserves power over the case where no validation of a false positive is accomplished and mobile device 100 needlessly awakens from a low-power mode for a longer period of time before returning to a low-power mode. Furthermore, providing context in advance of the triggering data 310 detected by sensor processor 172 may facilitate noise suppression if the acoustic environment itself turns out to be of no interest. For example, determining the noise characteristics that occur before the suspected triggering data 310, allows the second processor to remove that noise during the triggering data validation by the second processor). In some embodiments, the validation may even be done by the sensor processing unit 170 itself. For example, in a very low power mode the sensor processing unit 170 may use a basic algorithm to detect the triggering data, and if the triggering data is detected, the sensor processing unit 170 may validate the triggering data itself using a more sophisticated algorithm which may use e.g., the noise characteristics determined (and buffered) before the triggering data, and may require a slightly higher power mode. Such embodiments enable a reduction of false positives at the sensor processing unit 170 level, and avoids unnecessary waking up the host processor.

Extending the buffered content to a time before the start of the triggering data 310 in the fashion illustrated in FIG. 3D also allows a glimpse of the context at the time before the triggering data 310 was detected by sensor processor 172. The context may be an environmental context, a context of what the user was doing in the real world (riding a train, walking, etc.), and/or some other context. In some instances, the triggering data 310 itself may have been a direct reaction to something that happened in the environment (e.g., a voice on TV, a fire-truck siren, an airport terminal announcement, a song, etc.). For example, a user may ask “OK Google,” as triggering data 310, followed by an instruction of “what is this song.” Using the technique illustrated in FIG. 3D, circular data buffer 177 will already be filled with part of the song for immediate analysis. The data before the triggering data may be of relevance to the triggering data or to any command data that may follow the triggering data. Therefore, conserving this data by placing the start-end marker before the triggering data may provide additional useful information. In some embodiments, the sensor processing unit 170 may be able to analyze some of the context, and may adapt the position of the markers, such as e.g., start-end marker 330, based on the detected context. For example, for some applications a larger section of context data covering a wider time spam may be useful, meaning that the start-end market 330 is positioned at a lower memory position, at a larger distance from the start of the triggering data 310.

Host Processor Preoccupation

Once triggering data 310 has been detected, sensor processor 172 may make a decision to send a command, such as an interrupt, to alert a second processor, such as host processor 110. There is no telling what the host processor 110 may be doing. It may be asleep or in a low-power mode, or it may be pre-occupied with one or more tasks that prevent an immediate response. If preoccupied, it may take some amount of time for the host processor to respond to the command. During this wait time between sending a command and notification to sensor processor 172 that host processor 110 is responsive, sensor processor 172 will keep filling the circular data buffer 177 with sensor data that is received after triggering data 310. In many embodiments, the data received and buffered immediately after the triggering data 310 contains a command, instruction, or request from the user. Once host processor 110 is available, sensor processor 172 will start reading data out to host processor 110 from where start-end marker 330 (which doubles as the initial position of a read marker) is positioned. While reading the buffered data out to host processor 110, circular data buffer 177 continues being filled with data received from the sensor 178. The read speed must be as fast or faster than real-time in order not to get ‘overtaken’ by the write pointer of circular data buffer 177. Any processing that was being done by sensor processor 172 (e.g., noise cancelation, compression, etc.) may continue or be discontinued. In some embodiments, as soon as the host processor 110 is available to process data, all data from circular data buffer 177 is transferred to a buffer/memory (e.g., host memory 130) associated with host processor 110, and the new incoming data from sensor 178 is directly transferred to host processor 110 and/or its buffer.

Host Processor Wake-up

Once triggering data 310 has been detected, sensor processor 172 may make a decision to send a command, such as an interrupt, to wake host processor 110 from a low-power mode so that it enters a higher power mode where it is capable of performing more tasks. It will take some amount of time for the wake-up to occur. During this wait time between sending a wake-up command and notification to sensor processor 172 that host processor 110 is powered up to a higher power mode, sensor processor 172 will keep filling the circular data buffer 177 with sensor data that is received after triggering data 310. In many embodiments, the data received and buffered immediately after the triggering data 310 contains a command, instruction, or request from the user. Once host processor 110 is awake, sensor processor 172 will start reading data out to host processor 110 from where start-end marker 330 (which doubles as the initial position of a read marker) is positioned. While reading the buffered data out to host processor 110, circular data buffer 177 continues being filled with data received from the sensor 178. The read speed must be as fast or faster than real-time in order not to get ‘overtaken’ by the write pointer of circular data buffer 177. Any processing that was being done by sensor processor 172 (e.g., noise cancelation, compression, etc.) may continue or be discontinued. In some embodiments, as soon as the host processor 110 is awake, all data from circular data buffer 177 is transferred to a buffer/memory (e.g., host memory 130) associated with host processor 110, and the new incoming data from sensor 178 is directly transferred to host processor 110 and/or its buffer.

Limited Wake-up

As discussed above and elsewhere herein, circular data buffer 177 may be used to store the received data from a sensor 178 while host processor 110 is in low-power mode and while waiting for host-processor 110 to start up or awaken to a higher power mode. However, in some embodiments, host processor 110 does not need to be awakened, but can remain asleep/in a low-power mode, depending on the commands, instructions, or requests (if any) which follow triggering data 310. That is, for simple commands, instructions, or requests that can be interpreted and carried out by sensor processor 172, a wake-up command is not sent from sensor processor 172 to host processor 110. Instead, the wake-up command is limited to being sent in response to the occurrence of more complex commands, instructions, or requests than can be interpreted and/or carried out by sensor processor 172 or intermediate processor or hardware that might otherwise be notified/controlled by sensor processor 172. Consider an example, where the user speaks “OK Google” which is interpreted by sensor processor 172 as triggering data 310, and follows this by speaking “set the alarm for 6 AM.” In an embodiment where sensor processor 172 is configured to recognize certain instructions, such as alarm setting instructions, sensor processor 172 may set the alarm of mobile device 100 without waking host processor 110. In these limited-wakeup embodiments, the buffering needs to be longer than simply storing the triggering data 310 until the host processor 110 wakes up from a low-power more. The sizing of circular data buffer 177 depends on the types of commands required to be recognized. For very low-power implementations, only limited short commands may be allowed to reduce the buffer size and the associated power consumption of sensor processing unit 170.

Although the examples herein mainly focus on an acoustic sensor 178 with keyword spotting being accomplished to detect triggering data 310, they are not so limited. It should be appreciated that the same principles also apply after triggering data is detected in received data from a motion sensor, image sensor, or other sensor. For example, triggering data may be detected after receiving motion sensor data which measures a predefined motion triggering event or after receiving image sensor data represents a predefined visual triggering event. Following such triggering data detection, processing system 172 may send a command to a second processor, such as a host processor, and/or take action of its own. The command may alert, awaken, or initiate a process at the second processor.

Adaptive Compression

The following fundamental classes of compression can be distinguished and utilized with embodiments described herein: 1) No compression (highest data rate, and no computational power spent on compression/decompression); 2) Lossless compression (medium data rate, dependent on compressibility of received data, and output after decompression is indistinguishable from data that has not been compressed); and 3) Lossy compression (lowest data rate of the three levels, independent of captured data, requires the most processing power, and after decompression the decompressed data may be degraded).

Unlike compression classes 1 and 2, methods of class 3 have the potential to degrade the performance of certain detection and classification algorithms, due to degradation of received data after decompressing. Depending on the application, this may be acceptable. For instance, lossy compression may be acceptable for the triggering data 310 portion of the buffered data that the sensor processor 172 has already processed before compression. This is because the one of the only purposes of saving the triggering data it is validating the detection result on another processor.

In order to make appropriate trade-offs between the data reduction rate from compression and the performance of the detection or recognition task performed, the compression mechanism is adaptive. For example, FIGS. 3B-3D illustrate the use of no compression (e.g., class 1) with respect to received data that is buffered, while FIGS. 3E-3G show some examples of adapting compression from class 1 to class 2 and/or class 3.

FIG. 3E illustrates example data buffering operations with the circular data buffer 177 of FIG. 3A which take place in response to the sensor processor (e.g., 172) detecting triggering data 310, according to various embodiments. FIG. 3E illustrates a write marker 320 positioned above buffer address 311-5, a buffer start-end marker 330 positioned at the beginning of triggering data 310, and a data-marker 340 at the end of triggering data 310 in the manner illustrated in FIG. 3B. After detection of triggering data 310, sensor processor 172 has sent a command (e.g., a wake-up command or other command) to a second processor (e.g., to host processor 110 or an external processor 210). As illustrated in FIG. 3E, the command is sent at a time/position of circular data buffering indicated by arrow 361. It should be appreciated that there may be some time required for sensor processor 172 to analyze the triggering data 301 locally, so there may be some time delay before the end of the triggering data and the time the signal to wake up the host processor is send, accordingly in some embodiments 361 may actually be shifted to 311-16, 311-17, etc, due to analysis lag. Later, at a time/position of circular data buffering indicated by arrow 362, sensor processor 172 receives a notification that host processor 110 has powered up from its low-power state and is ready to receive data.

Font size of the letters in the buffer addresses visually depicts compression of the represented received data, with the largest font representing uncompressed data and with shifts to smaller fonts representing increased compression. In region 350, a first class of compression (e.g., no compression) is employed in buffer addresses 311-6, 311-7, and 311-8 for received data that was buffered before triggering data 310 and is also employed again, later in time, in buffer address 311-5 for received data that was buffered (and overwritten) after notification that processor 110 had awoken/powered-up/become available (as indicated by arrow 362). Region 350 also covers triggering data 310 in buffer addresses 311-9 through 311-15. In regions 351, a second class of compression (e.g., lossless compression) has been employed for buffering of data received after the triggering data 310 but before notification that host processor 110 had awoken/powered up at 362. In this example, the compression changes from a first class of compression to a second class of compression at the end of the triggering data 310. It may also change back to the first class of compression, as illustrated at arrow 362, after notification that processor 110 had awoken/powered-up/become available. In one embodiment, the first class of compression may consist of a higher level of compression compared to the second class of compression because the triggering data 310 will not be reanalyzed. In another embodiment, the first class of compression may consist of a lower level of compression compared to the second class of compression because the triggering data 310 will be reanalyzed, and the higher level of compression of the second class enables a more efficient storage of data after the triggering data, 310 such as e.g., a command, which is typically longer than the triggering data 310.

FIG. 3F illustrates example data buffering operations with the circular data buffer 177 of FIG. 3A which take place in response to the sensor processor (e.g., 172) detecting triggering data 310, according to various embodiments. FIG. 3F illustrates a write marker 320 positioned above buffer address 311-5, a buffer start-end marker 330 positioned at the beginning of triggering data 310, and a data-marker 340 positioned at the end of triggering data 310 in the manner illustrated in FIG. 3B. After detection of triggering data 310, sensor processor 172 has sent a command (e.g., a wake-up command or other command) to a second processor (e.g., to host processor 110 or an external processor 210). This command is sent at a time/position of circular data buffering indicated by arrow 361. Later, at a time/position of circular data buffering indicated by arrow 362, sensor processor 172 receives a notification that host processor 110 has powered up from its low-power state.

Font size of the letters in the buffer addresses visually depicts compression of the represented received data, with the largest font representing uncompressed data and with shifts to smaller fonts representing increased compression. In region 350, a first class of compression (e.g., no compression) is employed in buffer addresses 311-6, 311-7, and 311-8 for received data that was buffered before triggering data 310 and is also employed in buffer address 311-5 for received data that was buffered (and overwritten) after notification that processor 110 had awoken/powered-up/become available (as indicated by arrow 362). Region 350 also covers triggering data 310 in buffer addresses 311-9 through 311-15. In region 351, a second class of compression (e.g., lossless compression) has been employed for buffering. In regions 352, a third class of compression (lossy compression) has been employed for buffering data received after the triggering data 310 for buffer addresses 311-17 to 311-n. In region 353, a more aggressive form of the third class of compression has been employed for buffering data into buffer addresses 311-1 to 311-4, until notification that host processor 110 had awoken/powered-up/become available. The second class of compression may have a lower level of compression than the third class of compression, for example, the second class may be lossless compression and the third class may be lossy compression.

FIG. 3F illustrates that as circular data buffer 177 gets filled following detection of triggering data 310, the compression is increased. Many different scenarios are possible while increasing the compression as the buffer fills. Different sections of the buffer may use the same compression algorithm but with a different strengths or bit rates, or may use different algorithms. The buffer fill level, which is given, for example, by the distance of the current circular data buffer write pointer 320 from start-end marker 330, can be used for controlling the data compression rate. Alternatively, the buffer fill level may be determined with respect to the available space for the command, being from the end of the triggering data 310 until the start-end marker 330. Sensor processor 172 determines the buffer fill level or level of fullness. In some embodiments, this involves progressively moving to higher compression rates as the buffer fill level approaches start-end marker 330. When switching between compression methods with different processing delays, care must be taken that the algorithms are delay-aligned. In some embodiments, cross-fading between different sections may also be used, with different widths of the fading (which may depend on mechanisms used or signal content). This means that in the overlap regions two compression schemes run in parallel, which decreases buffer efficiency and creates a temporary spike in the data rate but may increase quality. In some embodiments, a compression scheme is used that adds a lossless complementary layer to a lossy core stream (e.g., the WavPack audio compression format), and as the buffer fills up, the lossless complementary layer is dropped.

Buffer locations at which the compression scheme is changed need to be known, and are typically fixed in advance and known to sensor processor 172 or else are marked and stored (such as at the end of circular data buffer 177).

The change in compression may depend on the buffer fill level, which may be determined in the size of allocated memory or in percentage, fractions. These fractions may be identical, for example, a first third of the buffer may use a first compression level, a second third of the buffer may use a second compression level, and a last third of the buffer may use a third compression level. Alternatively, the size of the fractions may vary, for example, a first half of the buffer may use a first compression level, then for the second half, a first quarter of the buffer may use a second compression level, and a last quarter of the buffer may use a third compression level. The compression strength, or the effective gain in space, may increase e.g., in a linear or more aggressive fashion.

FIG. 3G illustrates example data buffering operations with the circular data buffer 177 of FIG. 3A which take place in response to the sensor processor (e.g., 172) detecting triggering data 310, according to various embodiments. FIG. 3G illustrates a write marker 320 positioned above buffer address 311-6, a buffer start-end marker 330 positioned at the beginning of triggering data 310, and a data-marker 340 positioned at the end of triggering data 310 in the manner illustrated in FIG. 3B. After detection of triggering data 310, sensor processor 172 has sent a command (e.g., a wake-up command or other command) to a second processor (e.g., to host processor 110 or an external processor 210). This command is sent at a time/position of circular data buffering indicated by arrow 361. Later, at a time/position of circular data buffering indicated by arrow 362, sensor processor 172 receives a notification that host processor 110 has powered up from its low-power state.

Font size of the letters in the buffer addresses visually depicts compression of the represented received data, with the largest font representing uncompressed data and with shifts to smaller fonts representing increased compression. In regions 350, a first class of compression (e.g., no compression) is employed in buffer addresses 311-7 through 311-n, and continuing to 311-1 and 311-2, and again in buffer addresses 311-5 and 311-6. In region 350/351, the first class of compression is initially employed in the manner of the compression show in region 350 and then the data stored in this region is recompressed to a second level of compression which has a higher compression level that is also employed in region 351. The arrow 363 after buffer address 311-2 represents the point where a predetermined fill level of the buffer has been reached. At this point the sensor processing unit 170 decides to change the compression from a first class of compression to a second class of compression (e.g., lossless compression) of at least part of the data already in the buffer. The part that is recompressed may run back to the start-end marker 330, and this includes also recompression of the trigger data 310. Alternatively, the recompressing may run back to the end of the trigger data 310 (e.g., data marker 340), as is depicted in this example as is indicated by arrow 307, from buffer address 311-2 back to 311-16 shown as region 350/351. Note that FIG. 3G represents the situation after the recompression has taken place using a second class of compression. The recompression is performed by sensor processor 172 and involves reading the data that has a first class of compression, applying a second class of compression, and then writing back the data into the buffer. When the second class of compression has a higher compression level than the first class, the writing back the data will require less buffer addresses which will allow for more total data buffering (this aspect in not shown in FIG. 3G). After the recompression of region 350/351 from a first class of compression to a second class of compression, the next incoming data for buffer address 311-3 and further, as illustrated by region 351, is immediately stored using the second class of compression until notification that host processor 110 had awoken/powered-up/become available at the location of arrow 362. Such recompression adds more storage space to circular data buffer 177 to further delay overwrite of the start-end marker while waiting for a host-processor wakeup/power-up notification/availability. The example of FIG. 3G shows a single recompression after reaching a certain buffer fill level. In some embodiments, a plurality of recompressions may take place at different fill levels. For example, a first recompression using a second class of compression (e.g., lossless compression) may be applied at a first fill level, and at a later stage if even more space is required, a second recompression using a third class of compression (e.g., lossy compression) may be applied at a second fill level.

Adaptive Compression Settings

Adaptive compression settings, which include the choice of the compression strategy, compression algorithm, the number of different compression levels, and the variation in the compression strength, may depend on many different factors. For example, these settings may depend on the size or type of buffer. Bigger buffers may allow for more variation and a more optimal use of buffer size. The adaptive buffer settings may also depend upon the active application using the buffer, or the type of data stored in the buffer. Similarly, the settings may depend on the type of sensor for which the buffer is used, because the type of sensor determines the type of data produced, volume of data produced, and compressibility of the data. The settings may depend upon the required accuracy of the data or the required accuracy of the outcome of the process or function that the data is intended for. Triggering data 310 size or content may also influence the adaptive compression settings. In case the content of the triggering data 310 may determine the settings, this analysis and control must be done locally by sensor processor 172.

Adaptive compression settings may also depend on the power settings. For example, the more complicated the compression, the more power the calculations require, and so in a low-power mode certain compression settings may require too much power. In some embodiments, the settings may determine that although a certain amount of buffer size is available in hardware, not all of the hardware buffer may be used to save energy. This may depend on the trade-off between the energy it takes to operate the memory, and the energy it takes to run the compression algorithms. For example, less memory available may require more aggressive compression which may potentially require more energy.

Example Methods of Operation

FIGS. 4A-4G illustrate a flow diagram 400 of an example method of adaptive buffering in a mobile device having a host processor and a sensor processor coupled with the host processor, according to various embodiments. Procedures of this method will be described with reference to elements and/or components of one or more of FIG. 1, FIG. 2, and FIGS. 3A-3G. It is appreciated that in some embodiments, the procedures may be performed in a different order than described, that some of the described procedures may not be performed, and/or that one or more additional procedures to those described may be performed. Flow diagram 400 includes some procedures that, in various embodiments, are carried out by one or more processors under the control of computer-readable and computer-executable instructions that are stored on non-transitory computer-readable storage media (e.g., memory 176). It is further appreciated that one or more procedures described in flow diagram 400 may be implemented in hardware, or a combination of hardware with firmware and/or software.

With reference to FIG. 4A, at procedure 410 of flow diagram 400, in various embodiments, a sensor processor is used to buffer data received from a sensor that is operated by the sensor processor. The data is buffered by the sensor processor into a circular data buffer. In various embodiments, this comprises sensor processor 172 receiving data from a sensor 178 (e.g., an acoustic sensor 178-1) and then buffering the received data into a circular data buffer 177.

With continued reference to FIG. 4A, at procedure 420 of flow diagram 400, in various embodiments, responsive to the sensor processor detecting triggering data within the received data the procedures described 422 and 424 are carried out. In various embodiments, this comprises sensor processor 172 detecting for triggering data 310 in the form of a keyword/phrase in a digital audio stream, and/or a predefined motion event in a digital motion data stream from a motion sensor 178-3, and/or a predefined visual event in a digital visual data stream from an image sensor 178-n. Responsive to detection of triggering data 310, sensor processor 172 carries out other procedures, such as the procedures described in 422 and 424 of FIG. 4A.

With continued reference to FIG. 4A, at procedure 422 of flow diagram 400, in various embodiments, a start-end marker is set in the circular data buffer by the sensor processor. In various embodiments, this comprises sensor processor 172 setting start-end marker 330 in circular data buffer 177. The start-end marker can be set at various positions depending on, for example, the capabilities of sensor processor 172 to process triggering data 310 with/without validation and whether additional context data is being preserved for further processing apart from sensor processor 172. As is illustrated in FIG. 3B, in some embodiments sensor processor 172 sets the start-end marker at the beginning of triggering data 310. As is illustrated in FIG. 3C, in some embodiments sensor processor 172 sets the start-end marker at the end of triggering data 310. As is illustrated in FIG. 3D, in some embodiments sensor processor 172 sets the start-end marker at some predetermined distance (the distance may be measured in memory addresses or time as related to buffering speed) in advance of the beginning of triggering data 310 in order to capture context from received data buffered just before detection of triggering data 310.

With continued reference to FIG. 4A, at procedure 424 of flow diagram 400, in various embodiments, the sensor processor sends a command from the sensor processor to a second processor. In various embodiments, this comprises sensor processor 172 sending the command to the second processor which may be host processor 110 and/or a processor 210 that is external to mobile electronic device 100. It should be appreciated that external processor 210 may be located in another mobile electronic device, in a stand-alone computer system, in a datacenter (e.g., in a “cloud” of Internet connected shared on demand computing resources), etc. In some embodiments, the triggering data may be packages with or otherwise sent to the second processor along with or as part of the command.

In some embodiments, the command may be a wake-up command that causes the second processor to exit a low-power mode in which it conserves power but has fewer processing capabilities and enter a higher power mode, such as a full-power mode, which consumes more power but allows the second processor to perform more processing tasks. In other embodiments, the command may direct the second processor to perform another action or task, or initiate a process such as a web search or a response to a query posed by additional data that will be sent to the second processor.

In some embodiments where the command is a wake-up command sent to the second processor (e.g., host processor 110 or external processor 210), in response to either sensor processor 172 receiving notification that the second processor has exited a low-power mode or sensor processor 172 detecting that the second processor has left the low power mode, sensor processor 172 begins passing a portion of the buffered data to the second processor (e.g., to host processor 110 or its host memory/buffer 130, or to external processor 210 or a memory associated with it). Depending on positioning of a start-end marker 330 (and optionally a data marker 340) this can comprise passing one or more of triggering data 310, data received and buffered some fixed distance before triggering data 310, and data received after triggering data 310.

In some embodiments where the command is a wake-up command sent to the second processor, in response to either sensor processor 172 receiving notification that the second processor has exited a low-power mode or sensor processor 172 detecting that the second processor has left the low power mode, sensor processor 172 decreases a level of compression applied to data buffered into circular data buffer 177 if it had been increased at any time contemporaneous with or after buffering of the triggering data 310. FIGS. 3E, 3F, and 3G show examples of compression being decreased after the location of arrow 362, which represents a point at which sensor processor 172 received notification that second processor had exited its low-power mode. In other embodiments, data may not continue to be buffered, but instead it may be passed directly to the second processor (e.g., to host processor 110 or its host memory 130, to external processor 210 or its associated memory, or to some other designated destination).

With reference to FIG. 4B, at procedure 430 of flow diagram 400, in various embodiments, the method as described in 410-420 further comprises, in response to detection of the triggering data, buffering the data received after the triggering data at a different level of compression than was utilized before detection of the triggering data. As illustrated in FIGS. 3E, 3F, and 3G, this can comprise sensor processor 172 buffering received data into circular data buffer 177 at an increased level of compression as compared to compression level of the data buffered before the triggering data 310.

With reference to FIG. 4C, at procedure 440 of flow diagram 400, in various embodiments, the method as described in 410-430 further comprises buffering the triggering data at different level of compression than data received from the sensor after detection of the triggering data. This can comprise sensor processor 172 buffering received data into circular data buffer 177 at an increased level of compression as compared to compression level of the triggering data 310. It should be appreciated that, in various embodiments, the triggering data 310 may be more or less compressed than data buffered after triggering data 310.

With reference to FIG. 4D, at procedure 450 of flow diagram 400, in various embodiments, the method as described in 410-422 further comprises responsive to determining the circular data buffer has reached a predetermined level of fullness after setting of the start-end marker, after a data marker, or after some other fullness threshold has been satisfied, increasing compression of the received data before buffering into the circular data buffer. In some embodiments, sensor processor monitors the fullness of the circular data buffer 177. As illustrated in FIGS. 3F and 3G this can comprise sensor processor 172 buffering received data into circular data buffer 177 at an increasing levels of compression as circular data buffer 177 becomes increasingly full.

With reference to FIG. 4E, at procedure 460 of flow diagram 400, in various embodiments, the method as described in 410-422 further comprises responsive to determining the circular data buffer has reached a predetermined level of fullness after setting of the start-end marker, replacing data previously buffered into the circular data buffer with a more highly compressed version of the previously buffered data. In some embodiments, sensor processor monitors the fullness of the circular data buffer 177. As illustrated in FIG. 3G by dashed line 307, this can comprise sensor processor 172 re-compressing previously buffered data to a higher level of compression in response to a set point of fullness (as indicated by marker 363) being reached in circular data buffer 177.

With reference to FIG. 4F, at procedure 470 of flow diagram 400, in various embodiments, the method as described in 410-420 further comprises passing the triggering data from the sensor processor to the second processor for validation by the second processor. This can comprise sensor processor 172 reading the triggering data from circular data buffer 177 and passing it to host processor 110 or second processor 210. When triggering data 310 is demarked by a start-end marker 330 and/or one or more data-markers 340, this enables sensor processor 172 to quickly identify the specific portion of the buffered data to read and pass for validation.

With reference to FIG. 4G, at procedure 480 of flow diagram 400, in various embodiments, the method as described in 410-420 further comprises setting, by the sensor processor, at least one data marker for identification of specific portions of the buffered data. As depicted in FIGS. 3B and 3C a single data marker 340 can be set by sensor processor 172 to identify portions of the buffered data in circular data buffer 177 that correspond to the beginning or end of triggering data 310. As depicted in FIGS. 3B and 3C, data markers 340 may be utilized in conjunction with a start-end marker 330 to bound the start and end of triggering data 310 in circular data buffer 177. As depicted in FIG. 3D, a plurality of data markers 340 (e.g., 340-1 and 340-2) can be set by sensor processor 172 to identify portions of the buffered data in circular data buffer 177 that correspond to both the beginning and the end of triggering data 310. It should be appreciated that sensor processor 172 may utilize any number of data markers 340 to mark starting points, ending points, regions, or other aspects of portions of the data (e.g., triggering data, command data, context data) in order to provide reference points within or a frame of reference for the data that is being buffered.

As short summaries, this writing has disclosed at least the following broad concepts.

Concept 1. A method of adaptive buffering in a mobile device having a host processor and a sensor processor coupled with said host processor:

-   -   using said sensor processor to buffer data received from a         sensor that is operated by said sensor processor, wherein said         data is buffered by said sensor processor into a circular data         buffer; and     -   responsive to said sensor processor detecting triggering data         within said received data:         -   setting, by said sensor processor, a start-end marker in             said circular data buffer; and         -   sending a command from said sensor processor to a second             processor.

Concept 2. The method as recited in Concept 1, further comprising:

-   -   responsive to detection of said triggering data, buffering said         received data at a different level of compression than was         utilized before detection of said triggering data.

Concept 3. The method as recited in Concept 2, further comprising:

-   -   buffering said triggering data at a different level of         compression than data received from said sensor after detection         of said triggering data.

Concept 4. The method as recited in Concept 1 or 2, further comprising:

-   -   responsive to said circular data buffer reaching a predetermined         level of fullness, increasing compression of said received data         before buffering into said circular data buffer.

Concept 5. The method as recited in Concept 1 or 2, further comprising:

-   -   responsive to said circular data buffer reaching a predetermined         level of fullness, replacing data previously buffered into said         circular data buffer with a more highly compressed version of         said previously buffered data.

Concept 6. The method as recited in Concept 1, 2, 4, or 5, further comprising:

-   -   passing said triggering data from said sensor processor to said         second processor for validation by said second processor.

Concept 7. The method as recited in Concept 1, 2, 4, 5, or 6, further comprising:

-   -   setting, by said sensor processor, at least one data marker for         identification of specific portions of said buffered data.

Concept 8. The method as recited in Concept 7, wherein said setting, by said sensor processor, of said at least one data marker comprises:

-   -   setting said at least one data marker to identify said         triggering data in said buffered data.

Concept 9. The method as recited in Concept 1, 2, 4, 5, 6, or 7, wherein said setting, by said sensor processor, a start-end marker in said circular data buffer comprises:

-   -   setting said start-end marker at the end of said triggering         data.

Concept 10. The method as recited in Concept 1, 2, 4, 5, 6, or 7, wherein said setting, by said sensor processor, a start-end marker in said circular data buffer comprises:

-   -   setting said start-end marker at the beginning of said         triggering data.

Concept 11. The method as recited in Concept 1, 2, 4, 5, 6, 7, 9, or 10, wherein said sending a command from said sensor processor to a second processor comprises:

-   -   sending said command from said sensor processor to said second         processor, wherein said second processor is external to said         mobile device.

Concept 12. The method as recited in Concept 1, 2, 4, 5, 6, 7, 9, or 10, wherein said host processor of said mobile device is in a low-power mode, and wherein said sending a command from said sensor processor to a second processor of said mobile device comprises:

-   -   sending a wake-up command from said sensor processor to said         host processor.

Concept 13. The method as recited in Concept 12, further comprising:

-   -   responsive to said host processor exiting said low-power mode,         passing a portion of said buffered data to said second         processor.

Concept 14. The method as recited in Concept 12, further comprising:

-   -   responsive to said host processor exiting said low-power mode,         decreasing a level of compression of data buffered from said         sensor into said circular data buffer.

Concept 15. The method as recited in Concept 1, 2, 4, 5, 6, or 7, wherein said setting, by said sensor processor, a start-end marker in said circular data buffer comprises:

-   -   setting said start-end marker a predetermined distance in         advance of the beginning of said triggering data.

Concept 16. A sensor processing unit comprising:

-   -   a circular data buffer;     -   a sensor; and     -   a sensor processor configured to:         -   operate said sensor;         -   buffer data received from said sensor from said sensor into             said circular data buffer;         -   detect for triggering data within said data received from             said sensor; and         -   responsive to detection of said triggering data within said             received data:             -   set a start-end marker in said circular data buffer; and             -   send a command from said sensor processor, wherein said                 command is addressed to another processor external to                 said sensor processing unit.

Concept 17. The sensor processing unit of Concept 16, wherein said sensor processor is further configured to:

-   -   buffer said received data at a different level of compression         than was utilized before detection of said triggering data in         response to said detection of said triggering data.

Concept 18. The sensor processing unit of Concept 17, wherein said sensor processor is further configured to:

-   -   buffer said triggering data at a different level of compression         than data from received from said sensor after said detection of         said triggering data.

Concept 19. The sensor processing unit of Concept 16 or 17, wherein said sensor processor is further configured to:

-   -   increase compression of said received data before buffering into         said circular data buffer in response to determining said         circular data buffer has reached a predetermined level of         fullness.

Concept 20. The sensor processing unit of Concept 16, 17, or 19, wherein said sensor processor is further configured to:

-   -   replace data previously buffered into said circular data buffer         with a more highly compressed version of said previously         buffered data in response to determining said circular data         buffer has reached a predetermined fullness.

Concept 21. The sensor processing unit of Concept 16, 17, 19, or 20, wherein said command comprises:

-   -   a wake-up command for said another processor, said wake-up         command configured to cause said another processor to exit from         a low-power mode.

Concept 22. The sensor processing unit of Concept 21, wherein said sensor processor is further configured to:

-   -   pass a portion of said buffered data to said host processor in         response to determining said host processor has exited said         low-power mode.

Concept 23. The sensor processing unit of Concept 21, wherein said sensor processor is further configured to:

-   -   decrease a level of compression of data buffered from said         sensor into said circular data buffer in response to determining         said host processor has exited said low-power mode.

Concept 24. The sensor processing unit of Concept 16, wherein said sensor processor is configured to:

-   -   set said start-end marker at the end of said triggering data.

Concept 25. The sensor processing unit of Concept 16, 17, 19, 20, or 21, wherein said sensor processor is configured to:

-   -   set said start-end marker at the beginning of said triggering         data.

Concept 26. The sensor processing unit of Concept 16, 17, 19, 20, or 21 wherein said sensor processor is configured to:

-   -   set said start-end marker a predetermined distance in advance of         the beginning of said triggering data.

Concept 27. A mobile electronic device comprising:

-   -   a host processor;     -   a sensor processing unit coupled with said host processor and         configured to:         -   operate a sensor of said sensor processing unit;         -   buffer data received from said sensor from said sensor into             a circular data buffer of said sensor processing unit;         -   detect for triggering data within said data received from             said sensor; and         -   responsive to detection of said triggering data within said             received data:             -   set a start-end marker in said circular data buffer; and             -   send a command from said sensor processing unit, wherein                 said command is addressed to another processor external                 to said sensor processing unit.

Concept 28. The mobile electronic device of Concept 27, wherein said sensor processing unit is further configured to:

-   -   buffer said received data at a different level of compression         than was utilized before detection of said triggering data in         response to said detection of said triggering data.

Concept 29. The mobile electronic device of Concept 28, wherein said sensor processing unit is further configured to:

-   -   buffer said triggering data at a different level of compression         than data from received from said sensor after said detection of         said triggering data.

Concept 30. The mobile electronic device of Concept 27 or 28, wherein said sensor processing unit is further configured to:

-   -   increase compression of said received data before buffering into         said circular data buffer in response to determining said         circular data buffer has reached a predetermined level of         fullness after setting of said start-end marker.

Concept 31. The mobile electronic device of Concept 27, 28, or 30, wherein said sensor processing unit is further configured to:

-   -   replace data previously buffered into said circular data buffer         with a more highly compressed version of said previously         buffered data in response to determining said circular data         buffer has reached a predetermined fullness after setting of         said start-end marker.

Concept 32. The mobile electronic device of Concept 27, 28, 30, or 31, wherein said command comprises:

-   -   a wake-up command for said host processor, said wake-up command         configured to cause said another processor to exit from a         low-power mode.

Concept 33. The mobile electronic device of Concept 32, wherein said sensor processing unit is further configured to:

-   -   pass a portion of said buffered data to said host processor in         response to determining said another processor has exited said         low-power mode.

Concept 34. The mobile electronic device of Concept 32, wherein said sensor processing unit is further configured to:

-   -   decrease a level of compression of data buffered from said         sensor into said circular data buffer in response to determining         said another processor has exited said low-power mode.

Concept 35. The mobile electronic device of Concept 27, 28, 30, 31, or 32, wherein said sensor processing unit is configured to:

-   -   set said start-end marker at the end of said triggering data.

Concept 36. The mobile electronic device of Concept 27, 28, 30, 31, or 32, wherein said sensor processing unit is configured to:

-   -   set said start-end marker at the beginning of said triggering         data.

Concept 37. The mobile electronic device of Concept 27, 28, 30, 31, or 32, wherein said sensor processing unit is configured to:

set said start-end marker a predetermined distance in advance of the beginning of said triggering data.

Concept 38. The mobile electronic device of Concept 27, 28, 30, 31, or 32, where the another processor is one of: said host processor, and a processor external to said mobile electronic device.

CONCLUSION

The examples set forth herein were presented in order to best explain, to describe particular applications, and to thereby enable those skilled in the art to make and use embodiments of the described examples. However, those skilled in the art will recognize that the foregoing description and examples have been presented for the purposes of illustration and example only. The description as set forth is not intended to be exhaustive or to limit the embodiments to the precise form disclosed. Rather, the specific features and acts described above are disclosed as example forms of implementing the claims.

Reference throughout this document to “one embodiment,” “certain embodiments,” “an embodiment,” “various embodiments,” “some embodiments,” or similar term means that a particular feature, structure, or characteristic described in connection with the embodiment is included in at least one embodiment. Thus, the appearances of such phrases in various places throughout this specification are not necessarily all referring to the same embodiment. Furthermore, the particular features, structures, or characteristics of any embodiment may be combined in any suitable manner with one or more other features, structures, or characteristics of one or more other embodiments without limitation. 

What is claimed is:
 1. A method of adaptive buffering in a mobile device having a host processor and a sensor processor coupled with said host processor: using said sensor processor to buffer data received from a sensor that is operated by said sensor processor, wherein said data is buffered by said sensor processor into a circular data buffer; and responsive to said sensor processor detecting triggering data within said received data: setting, by said sensor processor, a start-end marker relative to said triggering data in said circular data buffer, wherein said start-end marker delays overwriting said triggering data until completion of an action; and sending a command to execute said action from said sensor processor to a second processor.
 2. The method as recited in claim 1, further comprising: responsive to detection of said triggering data, buffering said received data at a different level of compression than was utilized before detection of said triggering data.
 3. The method as recited in claim 2, further comprising: buffering said triggering data at a different level of compression than data received from said sensor after detection of said triggering data.
 4. The method as recited in claim 1, further comprising: responsive to said circular data buffer reaching a predetermined level of fullness, increasing compression of said received data before buffering into said circular data buffer.
 5. The method as recited in claim 1, further comprising: responsive to said circular data buffer reaching a predetermined level of fullness, replacing data previously buffered into said circular data buffer with a more highly compressed version of said previously buffered data.
 6. The method as recited in claim 1, further comprising: passing said triggering data from said sensor processor to said second processor for validation by said second processor.
 7. The method as recited in claim 1, further comprising: setting, by said sensor processor, at least one data marker for identification of specific portions of said buffered data.
 8. The method as recited in claim 7, wherein said setting, by said sensor processor, of said at least one data marker comprises: setting said at least one data marker to identify said triggering data in said buffered data.
 9. The method as recited in claim 1, wherein said setting, by said sensor processor, a start-end marker in said circular data buffer comprises: setting said start-end marker at the end of said triggering data.
 10. The method as recited in claim 1, wherein said setting, by said sensor processor, a start-end marker in said circular data buffer comprises: setting said start-end marker at the beginning of said triggering data.
 11. The method as recited in claim 1, wherein said sending a command from said sensor processor to a second processor comprises: sending said command from said sensor processor to said second processor, wherein said second processor is external to said mobile device.
 12. The method as recited in claim 1, wherein said host processor of said mobile device is in a low-power mode, and wherein said sending a command from said sensor processor to a second processor of said mobile device comprises: sending a wake-up command from said sensor processor to said host processor.
 13. The method as recited in claim 12, further comprising: responsive to said host processor exiting said low-power mode, passing a portion of said buffered data to said second processor.
 14. The method as recited in claim 1, wherein said setting, by said sensor processor, a start-end marker in said circular data buffer comprises: setting said start-end marker a predetermined distance in advance of the beginning of said triggering data.
 15. A sensor processing unit comprising: a circular data buffer; a sensor; and a sensor processor configured to: operate said sensor; buffer data received from said sensor into said circular data buffer employing a first class of compression; detect for triggering data within said data received from said sensor; and responsive to detection of said triggering data within said received data: set a start-end marker relative to said triggering data in said in said circular data buffer, wherein said start-end marker delays overwriting said triggering data until completion of an action; send a command to execute said action from said sensor processor, wherein said command is addressed to another processor external to said sensor processing unit; and change compression of said data received from said sensor to a second class of compression, wherein said second class of compression is different than said first class of compression.
 16. The sensor processing unit of claim 15, wherein said sensor processor is further configured to: increase compression of said received data before buffering into said circular data buffer in response to determining said circular data buffer has reached a predetermined level of fullness.
 17. The sensor processing unit of claim 15, wherein said sensor processor is further configured to: replace data previously buffered into said circular data buffer with a more highly compressed version of said previously buffered data in response to determining said circular data buffer has reached a predetermined fullness.
 18. The sensor processing unit of claim 15, wherein said command comprises: a wake-up command for said another processor, said wake-up command configured to cause said another processor to exit from a low-power mode.
 19. The sensor processing unit of claim 18, wherein said sensor processor is further configured to: pass a portion of said buffered data to said another processor in response to determining said another processor has exited said low-power mode.
 20. A mobile electronic device comprising: a host processor; a sensor processing unit coupled with said host processor and configured to: operate a sensor of said sensor processing unit; buffer data received from said sensor into a circular data buffer of said sensor processing unit employing a first class of compression; detect for triggering data within said data received from said sensor; and responsive to detection of said triggering data within said received data: set a start-end marker relative to said triggering data in said circular data buffer, wherein said start-end marker delays overwriting said triggering data until completion of an action; send a command to execute said action from said sensor processing unit, wherein said command is addressed to another processor external to said sensor processing unit; and change compression of said data received from said sensor to a second class of compression, wherein said second class of compression is different than said first class of compression; and responsive to receiving a notification that said action has been executed, change said compression of said data received from said sensor to said first class of compression.
 21. The mobile electronic device of claim 20, wherein said sensor processing unit is further configured to: increase compression of said received data before buffering into said circular data buffer in response to determining said circular data buffer has reached a predetermined level of fullness after setting of said start-end marker.
 22. The mobile electronic device of claim 20, wherein said sensor processing unit is further configured to: replace data previously buffered into said circular data buffer with a more highly compressed version of said previously buffered data in response to determining said circular data buffer has reached a predetermined fullness after setting of said start-end marker.
 23. The mobile electronic device of claim 20, wherein said command comprises: a wake-up command for said another processor, said wake-up command configured to cause said another processor to exit from a low-power mode.
 24. The mobile electronic device of claim 23, wherein said sensor processing unit is further configured to: pass a portion of said buffered data to said another processor in response to determining said another processor has exited said low-power mode.
 25. The mobile electronic device of claim 20, wherein said another processor is one of: said host processor, and a processor external to said mobile electronic device. 